import { createWebHistory, createRouter } from 'vue-router'
import Home from "../views/Home.vue"
import Login from "../views/Login.vue"


//配置路径关系
const routes = [
  {
    path: '/feedback',
    component: () => import('../views/Feedback.vue')
  },
  {
    path:"/",
    redirect:"/login"
  },
  {
    path:"/home",
    component:Home
  },
  {
    path:"/login",
    component:Login
  },
  {
    path:"/attlist",
    component:() => import("../views/Attractionslist.vue")
  },
  {
    path:"/attinfo",
    component:() => import("../views/AttInfo.vue")
  },
  {
    path:"/upavatar",
    component:() => import("../views/ChangeAvatar.vue")
  },
  {
    path:"/lygl",
    component:() => import("../views/Tourguide.vue")
  },
  {
    path:"/free",
    component:() => import("../views/Freetrp.vue")
  },
  {
    path:"/group",
    component:() => import("../views/Grouptours.vue")
  },
  {
    path:"/jdms",
    component:() => import("../views/Jiudms.vue")
  },
  {
    path:"/register",
    component:() => import("../views/Register.vue")
  },
  {
    path:"/smrz",
    component:() => import("../views/Smrz.vue")
},
  {
    path:"/dd",
    component:() => import("../views/Order.vue")
},
  {
    path:"/my",
    component:() => import("../views/My.vue")
},
  {
    path:"/fw",
    component:() => import("../views/Service.vue")
}, {
  path:"/qs"
  ,component:() => import("../views/Compatible.vue")
}, 
{
  path:"/outlet/:id/"
  ,component:() => import("../views/Outlet.vue")
},
{
  path:"/pay"
  ,component:() => import("../views/PutOrder.vue")
}, 
 {
  path: '/order/create',
  name: 'OrderCreate',
  component: () => import('../views/OrderCreate.vue')
},
 {
  path:"/set"
  ,component:() => import("../views/Setting.vue")
}, 
{
  path:"/user"
  ,component:() => import("../views/User.vue")
},
{
  path:"/kf"
  ,component:() => import("../views/Kf.vue")
},
]

//将创建的配置关系挂载到router实例上
const router = createRouter({
  history: createWebHistory(),
  routes
})

export default router